﻿@inherits AdminCompontentBase

<SSheetDialog EnableDomReload @bind-Value=_visible Title="@T("Edit Client")" ContentClass="px-sheet-dialog">
    <MCard Style="height: calc(100vh - 140px);">
        <MCardText Class="full-height">
            <SElevationTab Dense Class="pt-8 full-height selevationtab" @bind-Tab="_tab" Tabs='_tabHeader' ItemsClass="mt-8 full-height" ItemsStyle="overflow-y: auto;">
                <SElevationTabItem>
                    <Masa.Auth.Web.Admin.Rcl.Pages.Sso.Client.Section.Basics @bind-Dto=_basicDto />
                </SElevationTabItem>
                <SElevationTabItem>
                    <Masa.Auth.Web.Admin.Rcl.Pages.Sso.Client.Section.Consent @bind-Dto=_consentDto />
                </SElevationTabItem>
                <SElevationTabItem>
                    <Masa.Auth.Web.Admin.Rcl.Pages.Sso.Client.Section.Authentication @bind-Dto=_authenticationDto />
                </SElevationTabItem>
                <SElevationTabItem>
                    <Masa.Auth.Web.Admin.Rcl.Pages.Sso.Client.Section.ResourceScopes @bind-Dto=_clientScopesDto />
                </SElevationTabItem>
                <SElevationTabItem>
                    <DynamicComponent Type="@_otherType" Parameters=_componentMetadata />
                </SElevationTabItem>
            </SElevationTab>
        </MCardText>
        <MCardActions class="d-flex justify-space-between">
            <EnableSwitch @bind-Value="_basicDto.Enabled" />
            <SButton OnClick="SaveAsync" class="rounded-pill primary" MinWidth="100">@T("Save")</SButton>
        </MCardActions>
    </MCard>
</SSheetDialog>